<script setup>
import { ref } from 'vue';

// 列表
const list = ref(['关注', '热点', '美食汇', '去哪玩', '意识']);
// 索引
const index = ref(2);

// 获取最新的索引
const onActiveChange = (activeIndex) => {
	// console.log(activeIndex);
	index.value = activeIndex;
};
</script>

<template>
	<view class="container">
		<custom-tabs @activeChange="onActiveChange" :list="list" :activeIndex="index"></custom-tabs>
	</view>
</template>

<style lang="scss">
.container {
	// width: 500rpx;
	height: 500rpx;
	// background-color: skyblue;
}
</style>
